import request from '@/utils/request'

// 创建预案详情
export function createEmergencyReservePlainDetail(data) {
  return request({
    url: '/biz/emergency-reserve-plain-detail/create',
    method: 'post',
    data: data
  })
}

// 更新预案详情
export function updateEmergencyReservePlainDetail(data) {
  return request({
    url: '/biz/emergency-reserve-plain-detail/update',
    method: 'put',
    data: data
  })
}

// 删除预案详情
export function deleteEmergencyReservePlainDetail(id) {
  return request({
    url: '/biz/emergency-reserve-plain-detail/delete?id=' + id,
    method: 'delete'
  })
}

// 获得预案详情
export function getEmergencyReservePlainDetail(id) {
  return request({
    url: '/biz/emergency-reserve-plain-detail/get?id=' + id,
    method: 'get'
  })
}

// 获得预案详情分页
export function getEmergencyReservePlainDetailPage(query) {
  return request({
    url: '/biz/emergency-reserve-plain-detail/page',
    method: 'get',
    params: query
  })
}

// 导出预案详情 Excel
export function exportEmergencyReservePlainDetailExcel(query) {
  return request({
    url: '/biz/emergency-reserve-plain-detail/export-excel',
    method: 'get',
    params: query,
    responseType: 'blob'
  })
}
